const cp = require('cp');
require('./page.css');
let moduleExport = {};

let vm = avalon.define({
  $id: 'mc_step4_edit',
  wxappURL: '',
  init: () => {
    $.ajax({
      // url: 'http://192.168.1.63:8080/wxnotify/grant',
      url: 'https://www.ccian.com/gateway/wxnotify/grant?token=' + cp.getCookie('token'),
      type: 'GET',
      async: false,
      success: res => {
        vm.wxappURL = res.url;
      },
    });
  },
});

vm.init();
moduleExport.content = require('./content.html');
moduleExport.vm = vm;
module.exports = moduleExport;
